package com.cactus.utils;


import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.Data;

@Data
public class PageAdapter {

    private int begin;

    private int size;

    public PageAdapter(Page page) {
        this.begin = (int) ((page.getCurrent() - 1) * page.getSize());
        this.size = (int) page.getSize();
    }
}
